<?php

return [
    [
        'name' => 'content_theme',
        'title' => '内容主题',
        'type' => 'select',
        'group' => '',
        'visible' => '',
        'content' => [
            'light' => 'light',
            'dark' => 'dark',
            'wechat' => 'wechat',
            'ant-design' => 'ant-design',
        ],
        'value' => 'light',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'Markdown 输出的 HTML 所展现的外观，前端后台都能生效',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'code_theme',
        'title' => '代码风格',
        'type' => 'select',
        'group' => '',
        'visible' => '',
        'content' => [
            'github' => 'github',
            'ant-design' => 'ant-design',
            'xcode' => 'xcode',
            'abap' => 'abap',
            'algol' => 'algol',
            'algol_nu' => 'algol_nu',
            'arduino' => 'arduino',
            'autumn' => 'autumn',
            'borland' => 'borland',
            'bw' => 'bw',
            'colorful' => 'colorful',
            'dracula' => 'dracula',
            'emacs' => 'emacs',
            'friendly' => 'friendly',
            'fruity' => 'fruity',
            'igor' => 'igor',
            'lovelace' => 'lovelace',
            'manni' => 'manni',
            'monokai' => 'monokai',
            'monokailight' => 'monokailight',
            'murphy' => 'murphy',
            'native' => 'native',
            'paraiso-dark' => 'paraiso-dark',
            'paraiso-light' => 'paraiso-light',
            'pastie' => 'pastie',
            'perldoc' => 'perldoc',
            'pygments' => 'pygments',
            'rainbow_dash' => 'rainbow_dash',
            'rrt' => 'rrt',
            'solarized-dark' => 'solarized-dark',
            'solarized-dark256' => 'solarized-dark256',
            'solarized-light' => 'solarized-light',
            'swapoff' => 'swapoff',
            'tango' => 'tango',
            'trac' => 'trac',
            'vim' => 'vim',
            'vs' => 'vs',
        ],
        'value' => 'murphy',
        'rule' => 'required',
        'msg' => '',
        'tip' => '代码块所展现的外观。内置 github 等 36 套主题',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'code_show_number',
        'title' => '代码块显示行号',
        'type' => 'radio',
        'group' => '',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'open_baidu_tongji',
        'title' => '开启百度统计',
        'type' => 'radio',
        'group' => '',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '请前往 https://tongji.baidu.com 百度统计 获取配置信息',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'baidu_tongji',
        'title' => '百度统计脚本',
        'type' => 'string',
        'group' => '',
        'visible' => 'open_baidu_tongji=1',
        'value' => '',
        'rule' => 'remote(/addons/knowbase/index/check?param=url.baidu_tongji)',
        'msg' => '',
        'tip' => '格式如：https://hm.baidu.com/hm.js?你的标识符',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'open_login_diy_url',
        'title' => '登录时自定义跳转',
        'type' => 'radio',
        'group' => '',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '开启时,登录后将跳转到自定义的请求地址',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'login_diy_url',
        'title' => '自定义跳转',
        'type' => 'string',
        'group' => '',
        'visible' => 'open_login_diy_url=1',
        'value' => '',
        'rule' => 'remote(/addons/knowbase/index/check?param=inner_url.login_diy_url)',
        'msg' => '',
        'tip' => '仅限站内地址，可以带域名',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'only_one_project',
        'title' => '开启单项目',
        'type' => 'radio',
        'group' => '前台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '当不需要跳转到项目列表显示时，直接跳转到指定项目ID的文档',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'show_project_id',
        'title' => '项目ID',
        'type' => 'number',
        'group' => '前台配置',
        'visible' => 'only_one_project=1',
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '指定项目需开启，留空则跳转到权重最高的第一个知识库文档页',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'project_type',
        'title' => '项目列表类型',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '默认：带图片封面',
            '带内容：每个项目支持携带最多10个文档',
        ],
        'visible' => 'only_one_project=0',
        'value' => '0',
        'rule' => '',
        'msg' => '',
        'tip' => '',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'header_nav_type',
        'title' => '顶部类型',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '默认：左边是站点标题，右边是搜索框',
            '带导航栏：支持最多5个导航，可以带二级导航',
        ],
        'visible' => '',
        'value' => '0',
        'rule' => '',
        'msg' => '',
        'tip' => '【默认】：左边是站点标题，右边是搜索框，【带导航栏】支持最多5个导航，可以带二级导航',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'header_nav_link',
        'title' => '导航栏配置',
        'type' => 'text',
        'group' => '前台配置',
        'visible' => 'header_nav_type=1',
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '一行一个，<br/>格式：名称|地址|打开方式[self(当前窗口打开,默认)、blank(新窗口打开)]<br/>举例:<br/>百度|https://www.baidu.com|blank,<br/>二级导航栏格式：一级导航名称@二级导航1|https://www.baidu.com|blank',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'jump_link_type',
        'title' => '点击标题跳转',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '网站首页',
            '文档列表',
            '其他',
        ],
        'visible' => '',
        'value' => '0',
        'rule' => '',
        'msg' => '',
        'tip' => '进入某个知识库前台时，点击左上角的网站标题的跳转地址',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'jump_link',
        'title' => '跳转地址',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => 'jump_link_type=2',
        'value' => '',
        'rule' => 'remote(/addons/knowbase/index/check?param=url.jump_link)',
        'msg' => '',
        'tip' => '请输入其他跳转地址',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'web_title_type',
        'title' => '知识库标题',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '网站名称',
            '当前项目名称',
            '当前项目LOGO优先',
        ],
        'visible' => '',
        'value' => '0',
        'rule' => '',
        'msg' => '',
        'tip' => '进入某个知识库前台时，左上角标题名称显示整个网站的名称还是当前知识库的项目名称',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'nav_left_style',
        'title' => '知识库左侧菜单栏颜色',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '蓝色',
            '黑色',
        ],
        'visible' => '',
        'value' => '0',
        'rule' => '',
        'msg' => '',
        'tip' => '',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'project_title',
        'title' => '项目标题',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => '',
        'value' => '项目列表',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'head 头部显示title的内容',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'project_keywords',
        'title' => '项目关键字',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => '',
        'value' => '文档管理,结构化记录,提升知识的流转和传播效率,凝聚团队智慧',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'head 头部显示keywords的内容',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'project_description',
        'title' => '项目描述',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => '',
        'value' => '知识库管理 沉淀团队知识，优秀的文档管理体系能够帮助企业实现安全的文档存储，高效的文档搜索，形成完整的知识体系，带来极大的便利性.',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'head 头部显示description的内容',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'show_document_time',
        'title' => '文档显示修改时间',
        'type' => 'radio',
        'group' => '前台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '1',
        'rule' => 'required',
        'msg' => '',
        'tip' => '默认显示，不需要在标题下方显示时间可关闭',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'table_over_show',
        'title' => '表格超出显示',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '不换行，横向滚动条拖拽查看更多内容',
            '换行,显示全部',
        ],
        'visible' => '',
        'value' => '0',
        'rule' => '',
        'msg' => '',
        'tip' => '默认表格内容超出最大宽度时，会有横向滚动条提供拖拽查看',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'show_copyright',
        'title' => '显示备案和版权信息',
        'type' => 'radio',
        'group' => '前台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '1',
        'rule' => 'required',
        'msg' => '',
        'tip' => '在前端界面底部显示备案号和版权信息',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'copyright',
        'title' => '版权信息',
        'type' => 'string',
        'group' => '前台配置',
        'content' => [],
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '如©20xx-20xx 上海某高科技公司',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'beian',
        'title' => '备案号',
        'type' => 'string',
        'group' => '前台配置',
        'content' => [],
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '留空默认读取系统配置的 {$site.beian}',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'wa_beian',
        'title' => '公安备案信息',
        'type' => 'string',
        'group' => '前台配置',
        'content' => [],
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '会提取备案号单独跳转到备案中心，如：粤公网安备 xxxx号',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'friends_link',
        'title' => '底部友链',
        'type' => 'text',
        'group' => '前台配置',
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '一行一个，<br/>格式：名称|地址|打开方式[self(当前窗口打开,默认)、blank(新窗口打开)]<br/>举例:<br/>百度|https://www.baidu.com|blank',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'image_lazy_load',
        'title' => '图片懒加载',
        'type' => 'radio',
        'group' => '前台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '1',
        'rule' => 'required',
        'msg' => '',
        'tip' => '如果需要自定义loading图，可以将资源命名为loading.gif保存到/public/assets/addons/knowbase/imgs/loading.gif',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'static_cdn_type',
        'title' => 'CDN类型',
        'type' => 'select',
        'group' => '前台配置',
        'content' => [
            '关闭',
            'unpkg 加速',
            'zstatic 加速',
        ],
        'visible' => '',
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '开启时,将前端调用到的编辑器资源都切换到 CDN 服务,降低服务器的带宽压力，加快访问,如果CDN出现异常时，可以先暂时关闭',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'open_home_sitemap',
        'title' => '首页开启网站地图',
        'type' => 'radio',
        'group' => '前台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '当开启时插件首页可以显示网站地图，引导用户跳转查看所有文档<br/>默认网址为/knowbase.html,可以自行配置其他伪静态规则如sitemap.html<br/>如果伪静态去除插件标识符,直接访问网站首页就会显示',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'sitemap_title',
        'title' => '网站地图标题',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => 'open_home_sitemap=1',
        'value' => '网站地图',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'head 头部显示title的内容',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'sitemap_keywords',
        'title' => '网站地图关键字',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => 'open_home_sitemap=1',
        'value' => '文档管理,结构化记录,提升知识的流转和传播效率,凝聚团队智慧',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'head 头部显示keywords的内容',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'sitemap_description',
        'title' => '网站地图描述',
        'type' => 'string',
        'group' => '前台配置',
        'visible' => 'open_home_sitemap=1',
        'value' => '知识库管理 沉淀团队知识，优秀的文档管理体系能够帮助企业实现安全的文档存储，高效的文档搜索，形成完整的知识体系，带来极大的便利性.',
        'rule' => 'required',
        'msg' => '',
        'tip' => 'head 头部显示description的内容',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'show_ads',
        'title' => '开启推广',
        'type' => 'radio',
        'group' => '',
        'visible' => 'debug=1',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'ads_link',
        'title' => '推广内容',
        'type' => 'text',
        'visible' => 'show_ads=1',
        'group' => '',
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '一行一个',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'open_cdn',
        'title' => '开启CDN加速',
        'type' => 'radio',
        'group' => '',
        'visible' => 'debug=1',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'cdn_url',
        'title' => 'CDN加速地址',
        'type' => 'string',
        'visible' => 'open_cdn=1',
        'group' => '',
        'content' => [],
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '上传到CDN的OSS,保持相对目录结构不变,如 https://cdn.example.com',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'filter_tags',
        'title' => '过滤HTML标记',
        'type' => 'radio',
        'group' => '后台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '1',
        'rule' => 'required',
        'msg' => '',
        'tip' => '默认会过滤html标签，如：html、script、head的标签，会排除  <?php <?asp 诸如此类的文本',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'auto_upload_image_from_text',
        'title' => '粘贴文本自动上传图片',
        'type' => 'radio',
        'group' => '后台配置',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '如果粘贴的HTML文本中有带图片,自动传到服务器保存并替换原链接',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'upload_max_size',
        'title' => '文件上传大小(MB)',
        'type' => 'number',
        'group' => '后台配置',
        'visible' => '',
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '默认 10M,可能需要web容器和PHP一起设置最大上传才能生效',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'editor_theme',
        'title' => '编辑器主题',
        'type' => 'select',
        'group' => '后台配置',
        'visible' => '',
        'content' => [
            'classic' => '经典',
            'dark' => '暗黑',
        ],
        'value' => 'classic',
        'rule' => 'required',
        'msg' => '',
        'tip' => '编辑器所展现的外观',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'editor_mode',
        'title' => '编辑器模式',
        'type' => 'select',
        'group' => '后台配置',
        'visible' => '',
        'content' => [
            'wysiwyg' => '所见即所得',
            'ir' => '即时渲染',
            'sv' => '分屏预览',
        ],
        'value' => 'wysiwyg',
        'rule' => 'required',
        'msg' => '',
        'tip' => '编辑器所展现的外观',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'domain',
        'title' => '绑定二级域名前缀',
        'type' => 'string',
        'group' => '',
        'visible' => '',
        'content' => [],
        'value' => '',
        'rule' => '',
        'msg' => '',
        'tip' => '如果二级名域为 sub.example.com,那就输入 sub <br/> 需要在application/config.php 中<br/> 将 url_domain_deploy 设置为 true才能生效',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'rewrite',
        'title' => '伪静态',
        'type' => 'array',
        'group' => '',
        'content' => [],
        'value' => [
            'index/index' => '/knowbase$',
            'index/projects/p' => '/knowbase/projects/p/[:p]$',
            'index/projects' => '/knowbase/projects$',
            'index/project' => '/knowbase/project/[:id]$',
            'index/document' => '/knowbase/document/[:id]$',
            'index/rewrite_document' => '/knowbase/[:name]/[:id]$',
            'index/checkPage' => '/knowbase/checkPage$',
            'index/checkPassword' => '/knowbase/checkPassword$',
        ],
        'rule' => 'required',
        'msg' => '',
        'tip' => '',
        'ok' => '',
        'extend' => '',
    ],
    [
        'name' => 'show_user_navs',
        'title' => '知识库列表',
        'type' => 'radio',
        'group' => '个人中心',
        'visible' => '',
        'content' => [
            1 => '开启',
            0 => '关闭',
        ],
        'value' => '0',
        'rule' => 'required',
        'msg' => '',
        'tip' => '开启时，进入用户中心左侧菜单会获取当前用户组可见的知识库列表',
        'ok' => '',
        'extend' => '',
    ],
];
